Package com.amazonaws.ivs.chat.messaging.coroutines

Functions

Link copied to clipboard
suspend fun ChatRoom.awaitDeleteMessage(request: DeleteMessageRequest): DeleteMessageEvent

Sends a delete message request through a socket connection using suspending function.

Link copied to clipboard
suspend fun ChatRoom.awaitDisconnectUser(request: DisconnectUserRequest): DisconnectUserEvent

Sends a disconnect user request through a socket connection using suspending function.

Link copied to clipboard
suspend fun ChatRoom.awaitSendMessage(request: SendMessageRequest): ChatMessage

Sends a message request to the room through a socket connection using suspending function.

Link copied to clipboard
fun ChatRoom(    regionOrUrl: String,     tokenProvider: suspend () -> ChatToken,     maxReconnectAttempts: Int = 3,     id: String = UUID.randomUUID().toString()): ChatRoom

Construct a ChatRoom object using suspending tokenProvider function.

Link copied to clipboard
fun ChatRoom.deletedMessages(): Flow<DeleteMessageEvent>

Flow of DeleteMessageEvent instances delivered to a ChatRoom.

Link copied to clipboard
fun ChatRoom.disconnectedUsers(): Flow<DisconnectUserEvent>

Flow of DisconnectUserEvent instances delivered to a ChatRoom.

Link copied to clipboard
fun ChatRoom.receivedEvents(): Flow<ChatEvent>

Flow of ChatEvent instances delivered to a ChatRoom.

Link copied to clipboard
fun ChatRoom.receivedMessages(): Flow<ChatMessage>

Flow of ChatMessage instances delivered to a ChatRoom. The message can be sent by any of the users in the room, including the current user.

Link copied to clipboard
fun ChatRoom.stateChanges(): Flow<ChatRoom.State>

Flow for observing ChatRoom.state changes.